﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace 计科2015_31
{
    public partial class 实验1_4 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }
        protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e)
        {
            DropDownList2.Items.Clear();
            if (DropDownList1.SelectedValue == "北京市")
            {

                DropDownList2.Items.Add("东城区");
                DropDownList2.Items.Add("西城区");
                DropDownList2.Items.Add("朝阳区");
                DropDownList2.Items.Add("丰台区");
                DropDownList2.Items.Add("石景山区");
                DropDownList2.Items.Add("海淀区");
                DropDownList2.Items.Add("门头沟区");
                DropDownList2.Items.Add("房山区");
                DropDownList2.Items.Add("通州区");
                DropDownList2.Items.Add("顺义区");
                DropDownList2.Items.Add("昌平区");
                DropDownList2.Items.Add("大兴区");
                DropDownList2.Items.Add("怀柔区");
            }
            else if (DropDownList1.SelectedValue == "天津市")
            {

                DropDownList2.Items.Add("津南区");
                DropDownList2.Items.Add("河东区");
                DropDownList2.Items.Add("河西区");
                DropDownList2.Items.Add("东丽区");
                DropDownList2.Items.Add("红桥区");
                DropDownList2.Items.Add("南开区");
                DropDownList2.Items.Add("武清区");
                DropDownList2.Items.Add("和平区");
                DropDownList2.Items.Add("西青区");
                DropDownList2.Items.Add("滨海新区");
            }
        }
    }
}